﻿Namespace Kasa.Emanet
	Module Functions

		Function GunlukListe(Token As Token, islemtar As Date) As Recordset
			Q("select a.* from emanet a inner join (")
			Q("select distinct tahsiltar,tahsilno")
			Q("from emanet where islemtar >= @d1 and islemtar < @d2 and not (tediyeno is null and makbuz is null)) b on a.tahsiltar = b.tahsiltar and a.tahsilno = b.tahsilno")
			Dim Rs = Token.OpenSQL("*", islemtar, islemtar.AddDays(1))
			Return Rs
		End Function

	End Module
End Namespace
